
<template>
  <div class='total-sales'>
    <common-card title="今日交易用户数" :value="orderUser">
      <template>
        <v-chart :options="getOptions()"></v-chart>
      </template>
      <template v-slot:footer>
        <span>退货率 </span>
        <span class="emphasis">{{returnRate}}</span>
      </template>
    </common-card>
  </div>
</template>
<script>
import CommonCardMixin from '../../mixins/commonCardMixin'
import CommonDataMixin from '../../mixins/commonDataMixin'
export default {
  mixins: [CommonCardMixin, CommonDataMixin],
  methods: {
    getOptions () {
      return {
        color: ['#3398DB'],
        tooltip: {},
        series: [
          {
            name: '用户实时交易量',
            type: 'bar',
            data: this.orderUserTrend,
            barWidth: '60%'
          }
        ],
        xAxis: {
          show: false,
          type: 'category',
          data: this.orderUserTrendAxis
        },
        yAxis: {
          show: false
        },
        grid: {
          top: 0,
          left: 0,
          right: 0,
          bottom: 0
        }
      }
    }
  }
}
</script>
